package id.co.shuba.spamobile.util;

import java.util.List;

public class Str {
	public static boolean isNullOrEmpty(String str) {
		if (str == null) return true;
		return "".equals(str.trim());
	}
	
	public static boolean isEmpty(String str) {
		return "".equals(str.trim());
	}
	
	public static String join(List<String> list, String separator) {
		StringBuilder sb = new StringBuilder();		
		String sep = "";		
		for (String item : list) {
			sb.append(sep);
			sb.append(item);
			sep = separator;
		}
		return sb.toString();
	}
}
